<section class="course-course">
    <nav class="course-navigation">
        <div class="padding-wrapper">
            <section class="course-navigation-title">
                <img src="<?php echo $this->baseUrl(); ?>/images/icon_course_light.png" alt="Course" class="course-navigation-icon course-navigation-title-icon" />
                <span><?php echo $this->course->Name; ?></span>
            </section>
            
            <section class="course-navigation-image-wrapper">
                <img src="<?php echo $this->baseUrl(); ?>/assets/courses/<?php echo $this->course->Image; ?>" alt="Course" class="course-navigation-image" />
            </section>
            
            <section class="course-navigation-description">
                <?php echo $this->course->Description; ?>
            </section>
            
            <section class="course-navigation-stats-wrapper">
                <section class="course-navigation-title">
                    <img src="<?php echo $this->baseUrl(); ?>/images/icon_stats.png" alt="Stats" class="course-navigation-icon course-navigation-title-icon" />
                    <span>Statistics</span>
                </section>
                
                <ul class="course-stats">
                    <li><span><?php echo $this->course->CountAnnouncements; ?></span> Announcements</li>
                    <li><span><?php echo $this->course->CountBooks; ?></span></span> Books</li>
                    <!--<li><span>13</span> Contributors</li>-->
                    <li><span><?php echo $this->course->CountFollowers; ?></span> Followers</li>
                </ul>
                
                <section class="courses-buttons">
                    <?php
                        if(in_array($this->course->Id, $this->user->CourseIds))
                        {
                    ?>
                    <a href="<?php echo $this->baseUrl(); ?>/course/stopfollow/id/<?php echo $this->course->Id; ?>" class="unsubscribe">
                        unsubscribe
                    </a>
                    <?php
                        }
                        else
                        {
                    ?>
                    <a href="<?php echo $this->baseUrl(); ?>/course/follow/id/<?php echo $this->course->Id; ?>" class="subscribe">
                        follow
                    </a>
                    <?php
                        }
                    ?>
                </section>
            </section>
        </div>
    </nav>
    
    
    <div id="tabs">
        <ul>
            <li>
                <a href="#announcements">
                    Announcements
                </a>
            </li>
            <li>
                <a href="#books">
                    Books
                </a>
            </li>
        </ul>
        <div id="announcements" class="block-announcements-panel">
            <section class="block block-course-announcements">
                <div class="content">
                    <div class="feed">
                        <section class="block-announcements-list list">
                            <?php echo $this->annc_partial; ?>
                        </section>
                        <section class="block-announcements-pager pager">
                            <?php echo $this->annc_pager; ?>
                        </section>
                        <?php
                            if($this->user->Id == $this->course->AuthorId)
                            {
                        ?>
                        <section class="block-announcements-buttons editor-buttons">
                            <a href="<?php echo $this->baseUrl(); ?>/course/addannouncement/id/<?php echo $this->course->Id; ?>">
                                + add an announcement
                            </a>
                        </section>
                        <?php
                            }
                        ?>
                    </div>
                </div>
            </section>
        </div>
        <div id="books" class="block-course-books-panel">
            <section class="block block-course-books">
                <div class="content">
                    <div class="feed">
                        <section class="block-course-books-list list">
                            <?php echo $this->book_partial; ?>
                        </section>
                        <section class="block-course-books-pager pager">
                            <?php echo $this->book_pager; ?>
                        </section>
                        <?php
                            if($this->user->Id == $this->course->AuthorId)
                            {
                        ?>
                        <section class="block-course-books-buttons editor-buttons">
                            <a href="<?php echo $this->baseUrl(); ?>/course/addbook/id/<?php echo $this->course->Id; ?>">
                                + add an existing book
                            </a>
                        </section>
                        <?php
                            }
                        ?>
                    </div>
                </div>
            </section>
        </div>
    </div>
</section>
<input type="hidden" id="course_id" name="course_id" value="<?php echo $this->course->Id;?>" />